@Component
public class MailUtils {
    @Value("${mail.user}")
    private String USER;
    
    @Value("${mail.password}")
    private String PASSWORD;
    
    public boolean sendMail(String to, String text, String title) {
        // 邮件发送逻辑
    }
}